W-20244028: feat(webapp): Live Preview dev server error panel and proxy API#28
Open
ankitsinghkuntal09 wants to merge 10 commits intomainfrom
Open
W-20244028: feat(webapp): Live Preview dev server error panel and proxy API#28ankitsinghkuntal09 wants to merge 10 commits intomainfrom
ankitsinghkuntal09 wants to merge 10 commits intomainfrom
Conversation
Co-authored-by: Cursor <cursoragent@cursor.com>
…243732) - Error page with Quick Actions when dev server down - Proxy API: /_proxy/status, set-url, retry, start-dev, restart, force-kill, proxy-only - resolveDevCommand: npm run dev/yarn dev via node_modules/.bin - Tests: ProxyServer, ErrorPageRenderer, resolveDevCommand, fixtures Co-authored-by: Cursor <cursoragent@cursor.com>
…21111977) - ErrorPageRenderer: use getErrorPageTemplate() from package; remove local file read - Remove src/templates/error-page.html (template lives in webapps proxy package) - README: drop copy step for error-page; document package as source - resolveDevCommand/DevServerManager: generic monorepo comments Co-authored-by: Cursor <cursoragent@cursor.com>
…re-dangle, numeric-separators Co-authored-by: Cursor <cursoragent@cursor.com>
…static methods Co-authored-by: Cursor <cursoragent@cursor.com>
…dd Retry Detection to error page fallback Co-authored-by: Cursor <cursoragent@cursor.com>
…e varies in CI) Co-authored-by: Cursor <cursoragent@cursor.com>
…tions markup Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
bpbuch
reviewed
Feb 17, 2026
Comment on lines
+325
to
+326
| // AC1+AC4: Listen for "restart dev server" requests from the interactive error page | ||
| this.proxyServer.on('restartDevServer', () => { |
Contributor
There was a problem hiding this comment.
I don't think we want to add these event listeners to the proxy server in the CLI. The server can be managed directly in the terminal. Programmatic controls are likely only needed in the VS Code extension and should live in the extension itself.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
W-20244028 – Manage preview server lifecycle
What
GET /_proxy/status,POST /_proxy/start-dev,POST /_proxy/set-urlfor Live Preview / CLI integration.npm run dev/yarn devtonode_modules/.binbinary (avoids workspace conflicts).Files
src/commands/webapp/dev.ts: connects the error page actions (Start, Restart, Force Kill) to the CLI’s DevServerManager and proxy, and cleans up orphan dev serverssrc/proxy/ProxyServer.ts: adds the HTTP API (/_proxy/status, start-dev, restart, force-kill, set-url, retry, proxy-only) that the error page and Live Preview use, and adds proxy-only mode so the “dev server down” behavior can be turned off when the user only wants the proxy for API/auth.src/server/DevServerManager.ts:adds PID file persistence so the next CLI run can kill an orphan dev server (AC2), direct binary resolution so dev server start works in monorepos, getPid() so the CLI can force-kill the process, and correct cleanup of the PID file on stop/exit so the file doesn’t get stale.src/server/resolveDevCommand.tssrc/templates/ErrorPageRenderer.ts@W-20244028@

